﻿using Abp.Application.Services.Dto;
using Abp.Application.Services;
using Choucius.Boilerplate9.OutboundTasks.Dto;
using Choucius.Boilerplate9.DtoBase.MES;
using System.Collections.Generic;
using System.Threading.Tasks;

namespace Choucius.Boilerplate9.OutboundTasks
{
    /// <summary>
    /// 出库任务（MES下发）
    /// </summary>
    public interface IOutboundTaskAppService : IAsyncCrudAppService<OutboundTaskDto, int, PagedResultRequestDto, CreateOutboundTaskDto, OutboundTaskDto>
    {
        /// <summary>
        /// 根据工站ID获取当前（明日）出库任务
        /// </summary>
        /// <param name="workStationId">工站ID</param>
        /// <returns>出库任务</returns>
        OutboundTask GetCurrentTaskByWorkStation(int workStationId);

        /// <summary>
        /// 根据MES的工单，创建出库任务
        /// </summary>
        /// <param name="inputs">MES工单集合</param>
        Task CreateOutboundTaskFromMesAsync(List<MesDsDto> inputs);
    }
}
